﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="ucRegAgendaGeneral.ascx.cs"
    Inherits="wRegPadron.frmOpciones.ucRegAgendaGeneral" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<asp:UpdatePanel runat="server" ID="upAgendaMunicipal">
    <ContentTemplate>
        <table width="100%">
            <tr>
                <td colspan="2" valign="top" align="left" style="padding-left: 10px;">
                    <fieldset>
                        <legend>
                            <h3>
                                <asp:Label runat="server" ID="lblTitulo"></asp:Label>
                                <p>
                                    <small>
                                        <asp:Label runat="server" ID="lblDescripcion"></asp:Label></small></p>
                                <h3>
                                </h3>
                            </h3>
                        </legend>
                    </fieldset>
                </td>
            </tr>
            <tr>
                <td width="100%" align="center">
                    <table width="95%">
                        <tr>
                            <td align="center">
                                <asp:Panel runat="server" ID="panel1" Width="600">
                                    <div class="dropdown clearfix">
                                        <ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu" style="display: block;
                                            position: static; margin-bottom: 5px; width: 600px;">
                                            <table width="400">
                                                <tr>
                                                    <td align="left" colspan="2">
                                                        <div class="form-inline">
                                                            <asp:Label runat="server" ID="lbl" CssClass="text-info"> Área:</asp:Label>
                                                            <asp:DropDownList runat="server" ID="ddlArea" CssClass="tdCampoValorInput" OnSelectedIndexChanged="ddlArea_SelectedIndexChanged"
                                                                AutoPostBack="true" Visible="false">
                                                            </asp:DropDownList>
                                                            <asp:TextBox runat="server" ID="txtArea" CssClass="tdCampoValorInput" Width="250"></asp:TextBox>
                                                            <asp:AutoCompleteExtender ID="txtArea_AutoCompleteExtender" runat="server" ServiceMethod="InformacionAutoComp"
                                                                ServicePath="../AutoComplete.asmx" MinimumPrefixLength="1" CompletionSetCount="12"
                                                                CompletionInterval="1000" TargetControlID="txtArea">
                                                            </asp:AutoCompleteExtender>
                                                            <asp:Button runat="server" ID="btnAutocomplete" Text="Aceptar" CssClass="btn" OnClick="btnAutocomplete_Click" />
                                                        </div>
                                                    </td>
                                                </tr>
                                                <tr>
                                                    <td>
                                                        <br />
                                                    </td>
                                                </tr>
                                                <tr>
                                                    <td align="center" colspan="3">
                                                        <asp:GridView runat="server" ID="gvDependencias" AutoGenerateColumns="false" OnRowCommand="gvDependencias_RowCommand"
                                                            Width="400" EmptyDataText="No hay dependencias registradas">
                                                            <SelectedRowStyle CssClass="bselectedrow" />
                                                            <PagerStyle CssClass="bpagerstyle" HorizontalAlign="Left" />
                                                            <HeaderStyle Font-Size="Small" Font-Underline="true" Font-Bold="true" CssClass="bgrid" />
                                                            <Columns>
                                                                <asp:BoundField DataField="DEPARE_P_inID" HeaderText="idGrupo" ReadOnly="True">
                                                                    <ControlStyle Width="0px" CssClass="hid" />
                                                                    <FooterStyle CssClass="hid" Width="0px" />
                                                                    <HeaderStyle CssClass="hid" Width="0px" />
                                                                    <ItemStyle CssClass="hid" Width="0px" />
                                                                </asp:BoundField>
                                                                <asp:BoundField DataField="DEPARE_chNOMDEP" HeaderText="Dependencia" ItemStyle-HorizontalAlign="Left" />
                                                                <asp:BoundField DataField="DEPARE_chDIRDEP" HeaderText="Dirección" ItemStyle-HorizontalAlign="Left" />
                                                                <asp:ButtonField ButtonType="Image" ImageUrl="http://servicios.munijesusmaria.gob.pe/appweb/fuentes/images/user_edit.png"
                                                                    HeaderText="Editar" CommandName="Editar" ItemStyle-HorizontalAlign="Center" ControlStyle-CssClass="tdBotonImage" />
                                                                <asp:ButtonField ButtonType="Image" ImageUrl="http://servicios.munijesusmaria.gob.pe/appweb/fuentes/images/client_account_template.png"
                                                                    HeaderText="Responsables" CommandName="Seleccionar" ItemStyle-HorizontalAlign="Center"
                                                                    ControlStyle-CssClass="tdBotonImage" />
                                                                <asp:ButtonField ButtonType="Image" ImageUrl="http://servicios.munijesusmaria.gob.pe/appweb/fuentes/images/cross.png"
                                                                    HeaderText="Eliminar" CommandName="Eliminar" ItemStyle-HorizontalAlign="Center"
                                                                    ControlStyle-CssClass="tdBotonImage" />
                                                            </Columns>
                                                        </asp:GridView>
                                                    </td>
                                                </tr>
                                                <tr>
                                                    <td align="center" colspan="3">
                                                        <asp:Panel runat="server" ID="pPanelRegistro">
                                                            <table>
                                                                <tr>
                                                                    <td align="left" class="text-info">
                                                                        Orden:
                                                                    </td>
                                                                    <td align="left">
                                                                        <asp:TextBox ID="txtOrdenDependencia" runat="server" CssClass="tdCampoValorInput"></asp:TextBox>
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td align="left" class="text-info">
                                                                        Dependencia:
                                                                    </td>
                                                                    <td align="left">
                                                                        <asp:TextBox ID="txtDependencia" runat="server" CssClass="tdCampoValorInput"></asp:TextBox>
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td align="left" class="text-info">
                                                                        Dirección:
                                                                    </td>
                                                                    <td align="left">
                                                                        <asp:TextBox ID="txtDireccion" runat="server" CssClass="tdCampoValorInput"></asp:TextBox>
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td align="center" colspan="2">
                                                                        <asp:Button ID="btnAceptar" runat="server" CssClass="btn" OnClick="btnAceptar_Click"
                                                                            Text="Guardar" />
                                                                        <asp:Button ID="btnEditar" runat="server" CssClass="btn" OnClick="btnEditar_Click"
                                                                            Text="Actualizar" />
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td>
                                                                        <br />
                                                                    </td>
                                                                </tr>
                                                                <tr>
                                                                    <td align="center" colspan="2">
                                                                        <asp:Label ID="lblErrorDependencia" runat="server" CssClass="text-error"></asp:Label>
                                                                    </td>
                                                                </tr>
                                                            </table>
                                                        </asp:Panel>
                                                    </td>
                                                </tr>
                                            </table>
                                        </ul>
                                    </div>
                                </asp:Panel>
                            </td>
                        </tr>
                        <tr>
                            <td align="center" colspan="3">
                                <asp:Panel ID="pPanelConfirmacion" runat="server">
                                    <table>
                                        <tr>
                                            <td align="center" class="tdCampoError">
                                                ¿Eliminar la dependencia
                                                <asp:Label ID="lblDependencia" runat="server"></asp:Label>
                                                ?
                                            </td>
                                        </tr>
                                        <tr>
                                            <td align="center">
                                                <asp:Button ID="btnSi" runat="server" OnClick="btnSi_Click" Text="Si" />
                                                &nbsp;&nbsp;&nbsp;&nbsp;<asp:Button ID="btnNo" runat="server" OnClick="btnNo_Click"
                                                    Text="No" />
                                            </td>
                                        </tr>
                                    </table>
                                </asp:Panel>
                            </td>
                        </tr>
                    </table>
                </td>
            </tr>
            <tr>
                <td>
                    <br />
                </td>
            </tr>
            <tr>
                <td align="center">
                    <asp:Panel ID="pPanelResponsables" runat="server" Width="650px">
                        <div class="dropdown clearfix">
                            <ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu" style="display: block;
                                position: static; margin-bottom: 5px; width: 650px;">
                                <asp:Label ID="lblSeleccion" runat="server" CssClass="text-info"></asp:Label>
                                <br />
                                <asp:GridView ID="gvResponsables" runat="server" AutoGenerateColumns="false" CssClass="bgrid"
                                    OnRowCommand="gvResponsables_RowCommand" Width="600">
                                    <SelectedRowStyle CssClass="bselectedrow" />
                                    <PagerStyle CssClass="bpagerstyle" HorizontalAlign="Left" />
                                    <HeaderStyle Font-Bold="true" Font-Size="Small" Font-Underline="true" />
                                    <AlternatingRowStyle CssClass="baltrow" />
                                    <Columns>
                                        <asp:BoundField DataField="RESDEP_P_inID" HeaderText="" ReadOnly="True">
                                            <ControlStyle CssClass="hid" Width="0px" />
                                            <FooterStyle CssClass="hid" Width="0px" />
                                            <HeaderStyle CssClass="hid" Width="0px" />
                                            <ItemStyle CssClass="hid" Width="0px" />
                                        </asp:BoundField>
                                        <asp:BoundField DataField="NombrePer" HeaderText="Responsable" ItemStyle-HorizontalAlign="Left" />
                                        <asp:BoundField DataField="RESDEP_chANERES" HeaderText="Anexo" />
                                        <asp:BoundField DataField="RESDEP_chDIRRES" HeaderText="Directo" />
                                        <asp:BoundField DataField="RESDEP_chRPCRES" HeaderText="RPC" />
                                        <asp:ButtonField ButtonType="Image" CommandName="Editar" ControlStyle-CssClass="tdBotonImage"
                                            HeaderText="Editar" ImageUrl="http://servicios.munijesusmaria.gob.pe/appweb/fuentes/images/user_edit.png"
                                            ItemStyle-HorizontalAlign="Center" />
                                        <asp:ButtonField ButtonType="Image" CommandName="Eliminar" ControlStyle-CssClass="tdBotonImage"
                                            HeaderText="Eliminar" ImageUrl="http://servicios.munijesusmaria.gob.pe/appweb/fuentes/images/cross.png"
                                            ItemStyle-HorizontalAlign="Center" />
                                    </Columns>
                                </asp:GridView>
                                <br />
                                <asp:Panel ID="pPanelResponsable" runat="server">
                                    <table>
                                        <tr>
                                            <td align="center" class="tdCampoError">
                                                ¿Eliminar al responsable
                                                <asp:Label ID="lblResponsable" runat="server"></asp:Label>
                                                ?
                                            </td>
                                        </tr>
                                        <tr>
                                            <td align="center">
                                                <asp:Button ID="btnSi2" runat="server" OnClick="btnSi2_Click" Text="Si" />
                                                &nbsp;&nbsp;&nbsp;&nbsp;<asp:Button ID="btnNo2" runat="server" OnClick="btnNo2_Click"
                                                    Text="No" />
                                            </td>
                                        </tr>
                                    </table>
                                </asp:Panel>
                                <br />
                                <table width="50%">
                                    <tr>
                                        <td align="left" class="text-info">
                                            Responsable:
                                        </td>
                                        <td align="left">
                                            <asp:DropDownList ID="ddlResponsable" runat="server" CssClass="tdCampoValorInput"
                                                Width="250">
                                            </asp:DropDownList>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="left" class="text-info">
                                            Anexo:
                                        </td>
                                        <td align="left">
                                            <asp:TextBox ID="txtAnexo" runat="server" CssClass="tdCampoValorInput"></asp:TextBox>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="left" class="text-info">
                                            Directo:
                                        </td>
                                        <td align="left">
                                            <asp:TextBox ID="txtDirecto" runat="server" CssClass="tdCampoValorInput"></asp:TextBox>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="left" class="text-info">
                                            RPC:
                                        </td>
                                        <td align="left">
                                            <asp:TextBox ID="txtRPC" runat="server" CssClass="tdCampoValorInput"></asp:TextBox>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="left" class="text-info">
                                            Orden:
                                        </td>
                                        <td align="left">
                                            <asp:TextBox ID="txtOrden" runat="server" CssClass="tdCampoValorInput"></asp:TextBox>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            <br />
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="center" colspan="2">
                                            <asp:Button ID="btnGuardar" runat="server" CssClass="btn" OnClick="btnGuardar_Click"
                                                Text="Guardar" />
                                            <asp:Button ID="btnActualizar" runat="server" CssClass="btn" OnClick="btnActualizar_Click"
                                                Text="Actualizar" />
                                        </td>
                                    </tr>
                                    <tr>
                                        <td align="center" colspan="2">
                                            <asp:Label ID="lblErrorRegistro" runat="server" CssClass="text-error"></asp:Label>
                                        </td>
                                    </tr>
                                </table>
                            </ul>
                        </div>
                    </asp:Panel>
                </td>
            </tr>
        </table>
        </td> </tr> </table>
    </ContentTemplate>
</asp:UpdatePanel>
